package com.itheima.service;


import com.itheima.entity.PageResult;
import com.itheima.entity.QueryPageBean;
import com.itheima.pojo.Permission;
import com.itheima.pojo.Role;

import java.util.List;

//角色service
public interface RoleService {
    //分页
    public PageResult pageQuery(QueryPageBean queryPageBean);

    //添加
    public void add(Role role, Integer[] permissionIds);

    //查询权限列表用于回显到复选框
    public List<Permission> findAllp();

    //根据id查询
    public Role findById(Integer id);

    //根据角色id查询权限id的集合
    public List<Integer> findpIdByrId(Integer id);
    //修改
    public void edit(Role role, Integer[] permissionIds);

    //根据角色id删除
    public void deleteById(Integer id);

    public List<Role> findAll();
}
